package com.aierkeji.b2c.utils;

import org.springframework.data.domain.PageRequest;
import org.springframework.data.domain.Sort;

public class PageUtils {

	public static final PageRequest buildPageRequest(final int pageNo, final int pagzSize,
			final Sort sort) {
		return PageRequest.of(pageNo - 1, pagzSize,sort);
	}
	
	public static final PageRequest buildPageRequestNoSort(final int pageNo, final int pagzSize) {
		return PageRequest.of(pageNo - 1, pagzSize);
	}
}
